// Copyright © SixtyFPS GmbH <info@slint-ui.com>
// SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-commercial

import { Button, LineEdit, HorizontalBox } from "std-widgets.slint";

component Counter inherits Window {
    private property <int> value: 0;
    preferred-height: 30px;
    layout := HorizontalBox {
        LineEdit {
            enabled: false;
            text: root.value;
        }
        Button {
            text: "Count";
            clicked => { root.value += 1; }
        }
    }
}
